const originRequest = require('request') // 请求
const iconv = require('iconv-lite')  //编码
const cheerio = require('cheerio') //node jquery
// https://www.dy2018.com/i/104532.html
const sigleRequest = (url, callback) => {
	let option = {
		encoding: null
	}
	originRequest(url, option, callback)
}
for (let i = 104532; i < 104540; i++) {
	const url = `https://www.dy2018.com/i/${i}.html`
	sigleRequest(url, (err, res, body) => {
		const html = iconv.decode(body, 'gb2312')
		const $ = cheerio.load(html)
		console.log($('.title_all h1').text());

	})
}



